package com.example.adabank3.util;


/**
 * @author Administrator
 */
public class Result<T> {
    /**
    请求的返回状态
     */
    String status ;
    /**
     关于返回状态的具体信息
     */
    String message;
    /**
     服务在线信息
     */
    private T data;

    public Result(String status) {
        this.status = status;
    }

    public Result(String status, String message, T data) {
        this.status = status;
        this.message = message;
        this.data = data;
    }

    public Result() {

    }

    public static <T> Result<T> of(String msg) {

        return new Result<T>("OK",msg,null);
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }
}
